# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=py3-readchar
pkgver=2.0.0
pkgrel=2
pkgdesc=" Python library to read characters and key strokes"
url="https://github.com/magmax/python-readchar"
arch="noarch"
license="MIT"
depends="python3"
makedepends="py3-setuptools py3-flake8"
checkdepends="py3-pexpect py3-coverage py3-pytest py3-pytest-cov py3-wheel"
source="https://github.com/magmax/python-readchar/archive/$pkgver/py3-readchar-$pkgver.tar.gz"
builddir="$srcdir/python-readchar-$pkgver"

build() {
	python3 setup.py build
}

check() {
	python3 setup.py test
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
	# Remove installed tests
	rm -r "$pkgdir"/usr/lib/python*/site-packages/tests
}

sha512sums="92331e55080f5ebf55e313bd0e9562d55578df98ee116fa534a2ae47b43cbd9b19cf11263db821490a6b9ae5f62b78d378fd5b4c996d98a88c765af489b4d70f  py3-readchar-2.0.0.tar.gz"
